﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="GlobalInventoryRptList.aspx.cs" EnableViewState="false" EnableEventValidation="false"
    Inherits="WMS6.Web.Analytics.GlobalInventoryRptList" meta:resourcekey="Page" %>
<%@ PreviousPageType VirtualPath="~/Analytics/GlobalInventoryRptQuery.aspx" %>
<%@ Register Src="../UserControls/Pager.ascx" TagName="Pager" TagPrefix="uc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>GlobalInventoryRptList</title>
    <link href="../style/zh/1/css.css" type="text/css" rel="Stylesheet" id="mycss" />
    <link href="../Css/style.css" type="text/css" rel="stylesheet" />

    <script src="../Js/jquery.js" type="text/javascript"></script>

    <script src="../Js/jquery.simplemodal.js" type="text/javascript"></script>

    <script src="../Js/util.js" type="text/javascript"></script>

    <script src="../Js/InitPage.js" type="text/javascript"></script>

    <script src="../Js/checkbox.js" type="text/javascript"></script>

    <script type="text/javascript">
    
      window.onload = function(){
            initListPage();
        }
        
        function returnSearch()
        {
            var from = document.getElementById("hdnFrom").value;
            if(from != "")
            {
                window.location.href = "GlobalInventoryRptQuery.aspx";
            }
            else
            {
                window.history.go(-1);
            }
        }
    </script>

</head>
<body>
    <form id="F13611" runat="server">
    <div>
        <asp:ScriptManager ID="ScriptManager1" runat="server" />
        <div id="div_List_top">
            <table>
                <tr>
                    <td valign="bottom">
                        <asp:Label ID="lblGlobalInventoryRptList" runat="server" CssClass="label_header"
                            Text="全局库存查询" meta:resourcekey="lblUom"></asp:Label>
                    </td>
                    <td>
                        <asp:Button ID="btnRefresh" runat="server" CssClass="button" Enabled="False" Text="刷新"
                             OnClick="btnRefresh_Click" />
                    </td>
                </tr>
            </table>
        </div>
        <div class="blank8">
        </div>
        <asp:UpdatePanel ID="up1" runat="server">
            <ContentTemplate>
                <div id="div_List">
                <div id="div_List_msg">
                        <asp:Label ID="lblMsg" runat="server" CssClass="label_message"></asp:Label>
                    </div>
                    <asp:GridView ID="gvGlobalInventory" runat="server" AutoGenerateColumns="False" AllowSorting="True"
                        CssClass="gridview" OnRowDataBound="gvGlobalInventory_RowDataBound" OnSorting="gvGlobalInventory_Sorting" oninit="gvGlobalInventory_Init" 
                        PageSize="20" Width="2600px" meta:resourcekey="gvGlobalInventory">
                        <FooterStyle CssClass="GridViewFooterStyle" />
                        <RowStyle CssClass="GridViewRowStyle" />
                        <HeaderStyle CssClass="GridViewHeaderStyle" />
                        <AlternatingRowStyle CssClass="GridViewAlternatingRowStyle" />
                        <Columns>
                            <asp:BoundField HeaderText="序号" FooterText="序号" 
                                meta:resourcekey="BoundField">
                                <ItemStyle CssClass="GridViewRowWidth_40" />
                            </asp:BoundField>
                            <asp:TemplateField meta:resourcekey="TemplateField">
                                <HeaderTemplate>
                                    <img src="../Images/gvSettingpic.gif" id="img01" class="gvSettingImg" onclick="gvUserSetting('13611','gvGlobalInventory');" onmouseover="showGVUserSettingAlt(this);" alt="customize list" />
                                    <asp:CheckBox ID="CheckBox1" runat="server" 
                                        onclick="selectAll(this,'gvGlobalInventory');" 
                                        meta:resourcekey="CheckBox1" />
                                </HeaderTemplate>
                                <ItemTemplate>
                                    <asp:CheckBox ID="chbSelect" runat="server" 
                                        meta:resourcekey="chbSelect" />
                                </ItemTemplate>
                                <FooterTemplate>
                                    <asp:CheckBox ID="CheckBox2" runat="server" 
                                        onclick="selectAll(this,'gvGlobalInventory');" 
                                        meta:resourcekey="CheckBox2" />
                                </FooterTemplate>
                                <HeaderStyle HorizontalAlign="Center" CssClass="GridViewRowWidth_50" />
                                <ItemStyle HorizontalAlign="Center" CssClass="GridViewRowWidth_50" />
                            </asp:TemplateField>
                            <asp:BoundField DataField="SKU_ID" HeaderText="货品代码" FooterText="货品代码" SortExpression="SKU_ID"
                                meta:resourcekey="SKU_ID">
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:BoundField>
                            <asp:TemplateField FooterText="货品描述" HeaderText="货品描述" SortExpression="DESCR" 
                                meta:resourcekey="DESCR">
                                <ItemTemplate>
                                    <asp:Label ID="lblSkuDescr" runat="server" 
                                        Text='<%# Eval("DESCR").ToString() %>' meta:resourcekey="lblSkuDescr"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_200" />
                            </asp:TemplateField>
                            <asp:BoundField DataField="DESCR2" HeaderText="英文名" FooterText="英文名" SortExpression="DESCR2"
                                meta:resourcekey="DESCR2">
                                <ItemStyle CssClass="GridViewRowWidth_150" />
                            </asp:BoundField>
                            <asp:BoundField DataField="OWNER_ID" HeaderText="货主代码" FooterText="货主代码" 
                                SortExpression="OWNER_ID" meta:resourcekey="OWNER_ID">
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:BoundField>
                            <asp:BoundField DataField="SKU_CLASS_ID" HeaderText="货品分类" FooterText="货品分类" 
                                SortExpression="SKU_CLASS_ID" meta:resourcekey="SKU_CLASS_ID">
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:BoundField>
                            <asp:BoundField DataField="SKU_CLASS_ID" HeaderText="分类描述" FooterText="分类描述" 
                                SortExpression="SKU_CLASS_ID" meta:resourcekey="SKU_CLASS_Descr">
                                <ItemStyle CssClass="GridViewRowWidth_150" />
                            </asp:BoundField>
                            <asp:TemplateField FooterText="库存总数" HeaderText="库存总数" 
                                SortExpression="INVENTORY_QTY" meta:resourcekey="INVENTORY_QTY">
                                <ItemTemplate>
                                    <asp:Label ID="lblGlobalInventoryQty" runat="server" 
                                        Text='<%# GetPreferenceDigit(Eval("INVENTORY_QTY").ToString()) %>' 
                                        meta:resourcekey="lblGlobalInventoryQty"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                            <asp:BoundField DataField="UOM" HeaderText="单位" FooterText="单位" 
                                SortExpression="UOM" meta:resourcekey="UOM">
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:BoundField>
                            <asp:TemplateField FooterText="好货" HeaderText="好货" SortExpression="OK" 
                                meta:resourcekey="OK">
                                <ItemTemplate>
                                    <asp:Label ID="lblOK" runat="server" 
                                        Text='<%# GetPreferenceDigit(Eval("OK").ToString()) %>' 
                                        meta:resourcekey="lblOK"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                            <asp:TemplateField FooterText="坏货" HeaderText="坏货" SortExpression="DAMAGE" 
                                meta:resourcekey="DAMAGE">
                                <ItemTemplate>
                                    <asp:Label ID="lblDAMAGE" runat="server" 
                                        Text='<%# GetPreferenceDigit(Eval("DAMAGE").ToString()) %>' 
                                        meta:resourcekey="lblDAMAGE"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                            <asp:TemplateField FooterText="搁置" HeaderText="搁置" SortExpression="HOLD" 
                                meta:resourcekey="HOLD">
                                <ItemTemplate>
                                    <asp:Label ID="lblHOLD" runat="server" 
                                        Text='<%# GetPreferenceDigit(Eval("HOLD").ToString()) %>' 
                                        meta:resourcekey="lblHOLD"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                                <asp:TemplateField FooterText="冻结" HeaderText="冻结" SortExpression="ONHOLD_QTY" 
                                meta:resourcekey="ONHOLD_QTY">
                                <ItemTemplate>
                                    <asp:Label ID="lblONHOLD_QTY" runat="server" 
                                        Text='<%# GetPreferenceDigit(Eval("ONHOLD_QTY").ToString()) %>' 
                                        meta:resourcekey="lblONHOLD_QTY"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                            
                            <asp:TemplateField FooterText="预定库存" HeaderText="预定库存" 
                                SortExpression="ALLOCATED_QTY" meta:resourcekey="ALLOCATED_QTY">
                                <ItemTemplate>
                                    <asp:Label ID="lblALLOCATED_QTY" runat="server" 
                                        Text='<%# GetPreferenceDigit(Eval("ALLOCATED_QTY").ToString()) %>' 
                                        meta:resourcekey="lblALLOCATED_QTY"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                            <asp:TemplateField FooterText="可发库存" HeaderText="可发库存" 
                                SortExpression="AVAILABLE" meta:resourcekey="AVAILABLE">
                                <ItemTemplate>
                                    <asp:Label ID="lblAVAILABLE" runat="server" 
                                        Text='<%# GetPreferenceDigit(Eval("AVAILABLE").ToString()) %>' 
                                        meta:resourcekey="lblAVAILABLE"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                            <asp:BoundField DataField="VENDOR_ID" HeaderText="供应商名称" FooterText="供应商名称" 
                                SortExpression="VENDOR_ID" meta:resourcekey="VENDOR_ID">
                                <ItemStyle CssClass="GridViewRowWidth_200" />
                            </asp:BoundField>
                            <asp:BoundField DataField="EXTERNAL_LOT" HeaderText="外部批号" FooterText="外部批号" SortExpression="EXTERNAL_LOT"
                                meta:resourcekey="EXTERNAL_LOT">
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:BoundField>
                               <asp:TemplateField FooterText="生产日期" HeaderText="生产日期" 
                                SortExpression="PRODUCE_DATE" >
                                <ItemTemplate>
                                    <asp:Label ID="lblPRODUCE_DATE" runat="server" 
                                        Text='<%# GetPreferenceShortDate(Eval("PRODUCE_DATE").ToString()) %>' 
                                        meta:resourcekey="lblPRODUCE_DATE"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_150" />
                            </asp:TemplateField>
                             <asp:TemplateField FooterText="失效日期" HeaderText="失效日期" 
                                SortExpression="EXPIRY_DATE" >
                                <ItemTemplate>
                                    <asp:Label ID="lblEXPIRY_DATE" runat="server" 
                                        Text='<%# GetPreferenceShortDate(Eval("EXPIRY_DATE").ToString()) %>' 
                                        meta:resourcekey="lblEXPIRY_DATE"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_150" />
                            </asp:TemplateField>
                            <asp:TemplateField FooterText="总重量" HeaderText="总重量" SortExpression="TOTALWGT" 
                                meta:resourcekey="TOTALWGT">
                                <ItemTemplate>
                                    <asp:Label ID="lblTOTALWGT" runat="server" 
                                        Text='<%# GetPreferenceDigit(Eval("TOTALWGT").ToString()) %>' 
                                        meta:resourcekey="lblTOTALWGT"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                            <asp:TemplateField FooterText="总体积" HeaderText="总体积" SortExpression="TOTALCUBE" 
                                meta:resourcekey="TOTALCUBE">
                                <ItemTemplate>
                                    <asp:Label ID="lblTOTALCUBE" runat="server" 
                                        Text='<%# GetPreferenceDigit(Eval("TOTALCUBE").ToString()) %>' 
                                        meta:resourcekey="lblTOTALCUBE"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_100" />
                            </asp:TemplateField>
                            <asp:TemplateField FooterText="最后入库时间" HeaderText="最后入库时间" 
                                SortExpression="RECEIPT_DATE" meta:resourcekey="RECEIPT_DATE">
                                <ItemTemplate>
                                    <asp:Label ID="lblEXPECTED_RECEIPT_DATE" runat="server" 
                                        Text='<%# GetPreferenceShortDate(Eval("RECEIPT_DATE").ToString()) %>' 
                                        meta:resourcekey="lblEXPECTED_RECEIPT_DATE"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_150" />
                            </asp:TemplateField>
                            <asp:TemplateField FooterText="最后出库时间" HeaderText="最后出库时间" 
                                SortExpression="SHIPPED_DATE" meta:resourcekey="SHIPPED_DATE">
                                <ItemTemplate>
                                    <asp:Label ID="lblRECEIPT_DATE" runat="server" 
                                        Text='<%# GetPreferenceShortDate(Eval("SHIPPED_DATE").ToString()) %>' 
                                        meta:resourcekey="lblRECEIPT_DATE"></asp:Label>
                                </ItemTemplate>
                                <ItemStyle CssClass="GridViewRowWidth_150" />
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                </div>
                <div id="div_pager">
                    <uc1:Pager ID="PagerFooter" runat="server" OnFirst="btnFirst_Click" OnPrevious="btnPrevious_Click"
                        OnNext="btnNext_Click" OnLast="btnLast_Click" OnGoTo="GoTo_Click" />
                </div>
                <input type="hidden" runat="server" id="hdnFrom" />
            </ContentTemplate>
        </asp:UpdatePanel>
        <input type="hidden" id="hdnActionID" runat="server" />
        <div id="div_List_bottom">
            <table>
                <tr>
                    <td>
                        <asp:Button ID="btnSearch" runat="server" Text="<%$Resources:ButtonResource,btnSearch%>" CssClass="button" Enabled="False"
                            OnClientClick="javascript:window.location.href='GlobalInventoryRptQuery.aspx';return false;"
                            />
                    </td>
                    <td>
                        <asp:Button ID="btnReSearch" runat="server" Text="<%$Resources:ButtonResource,btnReSearch%>" CssClass="button" Enabled="False"
                            OnClientClick="javascript:returnSearch();return false;" 
                             />
                    </td>
                    <td>
                        <asp:Button ID="btnList" runat="server" Text="<%$Resources:ButtonResource,btnList%>" CssClass="button" Enabled="False"
                            OnClick="btnList_Click"  />
                    </td>
                    <td>
                        <asp:Button ID="btnExport" runat="server" Text="<%$Resources:ButtonResource,btnExport%>" CssClass="button" Enabled="False"
                            OnClick="btnExport_Click"  />
                    </td>
                </tr>
            </table>
        </div>
    </div>
    </form>
</body>
</html>
